package Testdmol2;

import java.util.Scanner;

/**
 * Created with IntelliJ IDEA.
 * Description:
 * User:周次煜
 * Testdmo1.Date: 2024-02-17
 * Time：21:18
 */
public class J2_17 {
    //    9. 获取一个数二进制序列中所有的偶数位和奇数位，分别输出二进制序列。

    public static void  main9(String[] args) {

        Scanner scan =new Scanner(System.in);
        int n= scan.nextInt();
        int a=n & (0x55555555);
        int b=n & (0xAAAAAAAA);
        System.out.println("奇数位为: "+a+"\n偶数位为: "+b);

    }
}

